package com.ruoyi.project.system.address.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.system.address.mapper.FlowAddressMapper;
import com.ruoyi.project.system.address.domain.FlowAddress;
import com.ruoyi.project.system.address.service.IFlowAddressService;
import com.ruoyi.common.utils.text.Convert;

/**
 * 推流Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-11-11
 */
@Service
public class FlowAddressServiceImpl implements IFlowAddressService 
{
    @Autowired
    private FlowAddressMapper flowAddressMapper;

    /**
     * 查询推流
     * 
     * @param flowId 推流主键
     * @return 推流
     */
    @Override
    public FlowAddress selectFlowAddressByFlowId(Long flowId)
    {
        return flowAddressMapper.selectFlowAddressByFlowId(flowId);
    }

    /**
     * 查询推流列表
     * 
     * @param flowAddress 推流
     * @return 推流
     */
    @Override
    public List<FlowAddress> selectFlowAddressList(FlowAddress flowAddress)
    {
        return flowAddressMapper.selectFlowAddressList(flowAddress);
    }

    /**
     * 新增推流
     * 
     * @param flowAddress 推流
     * @return 结果
     */
    @Override
    public int insertFlowAddress(FlowAddress flowAddress)
    {
        return flowAddressMapper.insertFlowAddress(flowAddress);
    }

    /**
     * 修改推流
     * 
     * @param flowAddress 推流
     * @return 结果
     */
    @Override
    public int updateFlowAddress(FlowAddress flowAddress)
    {
        return flowAddressMapper.updateFlowAddress(flowAddress);
    }

    /**
     * 批量删除推流
     * 
     * @param flowIds 需要删除的推流主键
     * @return 结果
     */
    @Override
    public int deleteFlowAddressByFlowIds(String flowIds)
    {
        return flowAddressMapper.deleteFlowAddressByFlowIds(Convert.toStrArray(flowIds));
    }

    /**
     * 删除推流信息
     * 
     * @param flowId 推流主键
     * @return 结果
     */
    @Override
    public int deleteFlowAddressByFlowId(Long flowId)
    {
        return flowAddressMapper.deleteFlowAddressByFlowId(flowId);
    }
}
